<template>
	<div class="padding10">
		<el-form :inline="true" :model="queryForm" @submit.native.prevent @keyup.enter.native="queryList">
			<el-form-item>
				<el-input prefix-icon="el-icon-search" v-model="queryForm.id" autocomplete="off" placeholder="请输入文章ID" clearable></el-input>
			</el-form-item>
			<el-form-item>
				<el-input prefix-icon="el-icon-search" v-model="queryForm.title" autocomplete="off" placeholder="请输入标题" clearable></el-input>
			</el-form-item>
			<el-form-item>
				<el-select
					v-model="queryForm.channelId"
					placeholder="请选择栏目"
					clearable
					@clear="selectClear"
					filterable
					:filter-method="
						query => {
							leftTreeFilterText = query
						}
					"
				>
					<el-option :label="sleLeftTreeName" :value="sleLeftTreeId">
						<!-- <el-input placeholder="输入关键字进行过滤" v-model="leftTreeFilterText" clearable style="margin-bottom: 10px"></el-input> -->
						<el-tree
							class="filter-tree"
							:data="leftTreeData"
							:props="defaultProps"
							default-expand-all
							highlight-current
							ref="tree"
							@node-click="chooseLeftTree"
							:filter-node-method="leftTreeFilterNode"
						></el-tree>
					</el-option>
				</el-select>
			</el-form-item>
			<!-- <el-form-item v-show="collapse.flag">
				<el-input
					prefix-icon="el-icon-search"
					v-model="queryForm.author"
					autocomplete="off"
					placeholder="请输入作者"
					clearable
				></el-input>
			</el-form-item> -->
			<el-form-item v-show="collapse.flag">
				<el-input prefix-icon="el-icon-search" v-model="queryForm.keywords" autocomplete="off" placeholder="请输入关键字" clearable></el-input>
			</el-form-item>
			<el-form-item v-show="collapse.flag">
				<el-input prefix-icon="el-icon-search" v-model="queryForm.publisher" autocomplete="off" placeholder="请输入发布人" clearable></el-input>
			</el-form-item>
			<el-form-item v-show="collapse.flag">
				<el-date-picker
					v-model="date"
					type="datetimerange"
					align="right"
					unlink-panels
					range-separator="-"
					start-placeholder="开始日期"
					end-placeholder="结束日期"
					:picker-options="pickerOptions"
					value-format="yyyy-MM-dd hh:mm:ss"
					@change="onQueryListDate"
				></el-date-picker>
			</el-form-item>
			<el-form-item v-show="collapse.flag">
				<fortress-select v-model="queryForm.status" :dictList="ArticleStatus_cmsList" placeholder="请选择状态" clearable filterable></fortress-select>
			</el-form-item>
			<el-form-item v-show="collapse.flag">
				<el-select v-model="queryFormtags" placeholder="请选择标签" clearable multiple>
					<el-option v-for="(item, index) in tagsList" :key="index" :label="item.name" :value="item.code"></el-option>
				</el-select>
			</el-form-item>
			<el-form-item>
				<el-button type="primary" size="medium" icon="el-icon-search" @click="queryList({ current: 1 })">搜索</el-button>
			</el-form-item>
			<el-form-item>
				<el-button type="primary" size="medium" icon="el-icon-refresh-left" @click="resetQueryForm">重置</el-button>
			</el-form-item>
			<el-form-item>
				<el-button type="text" @click="handleCollapseState">
					{{ collapse.label }}
					<i :class="collapse.icon"></i>
				</el-button>
			</el-form-item>
		</el-form>
		<el-row type="flex" justify="space-between">
			<el-col :span="24">
				<el-button size="medium" type="primary" icon="el-icon-document" v-if="$tools.hasPermission('cms:cmsArticle:save')" @click="handleEdit()">
					添加
				</el-button>
				<el-button @click="onCategoryVisible" :disabled="!multipleSelection.length" size="medium" type="success" icon="el-icon-menu" v-if="$tools.hasPermission('cms:cmsArticle:moveChannel')">
					转移分类
				</el-button>
				<el-button v-if="$tools.hasPermission('cms:cmsArticle:toDrafts')" :disabled="!multipleSelection.length" size="medium" type="warning" icon="el-icon-view" @click="toDrafts()">
					{{ queryForm.status == 7 ? "恢复" : "放入草稿箱" }}
				</el-button>
				<el-button
					:disabled="!multipleSelection.length"
					size="medium"
					type="danger"
					icon="el-icon-delete"
					v-if="$tools.hasPermission('cms:cmsArticle:toGarbage') && queryForm.status != 7"
					@click="handleDeleteBatch()"
				>
					放入回收站
				</el-button>
				<el-button
					:disabled="!multipleSelection.length"
					size="medium"
					type="danger"
					icon="el-icon-delete"
					v-if="$tools.hasPermission('cms:cmsArticle:toDelReal') && queryForm.status == 7"
					@click="onCompletelyDelete()"
				>
					彻底删除
				</el-button>
				<!-- <el-button :disabled="!crossState" size="medium" type="success" icon="el-icon-document-checked">发布</el-button> -->
			</el-col>
		</el-row>
		<div class="ditct">
			<i class="el-icon-download" style="margin-right: 10px; cursor: pointer" @click="handleExport"></i>
			<i class="el-icon-refresh" style="margin-right: 10px; cursor: pointer" @click="refresh"></i>

			<el-popover placement="bottom" width="180" trigger="click" title="列展示" popper-class="columnShows">
				<el-checkbox-group v-model="tableShowList">
					<el-checkbox v-for="item in tableList" :label="item.propName" :key="item.propName" :value="item.propName">
						{{ item.propDesc }}
					</el-checkbox>
				</el-checkbox-group>
				<i slot="reference" class="el-icon-s-operation" style="cursor: pointer"></i>
			</el-popover>
		</div>
		<el-tabs class="cmsarticle-el-tabs" @tab-click="tabClick">
			<el-tab-pane label="全部" name="" key="全部"></el-tab-pane>
			<el-tab-pane :label="item.name" :name="+item.code + 1 + ''" v-for="(item, index) in ArticleStatus_cmsList" :key="'tab' + index"></el-tab-pane>
			<el-tab-pane label="回收站" name="8" key="回收站"></el-tab-pane>
		</el-tabs>
		<!-- loading -->
		<loading :show="parentShow">
			<el-table @selection-change="handleSelectionChange" ref="multipleTable" :data="tableData" style="width: 100%; margin-bottom: 20px" row-key="id">
				<el-table-column type="selection" width="55" show-overflow-tooltip></el-table-column>

				<el-table-column v-if="$tools.isShow('id', tableShowList)" prop="id" label="文章ID" :show-overflow-tooltip="true" width="70px">
					<template #default="{row}">
						{{ row.id }}
						<fortress-copy :copyData="row.id"></fortress-copy>
					</template>
				</el-table-column>
				<el-table-column v-if="$tools.isShow('title', tableShowList)" prop="title" label="标题" :show-overflow-tooltip="true"></el-table-column>
				<el-table-column v-if="$tools.isShow('channelId', tableShowList)" prop="channelIdName" label="栏目" :show-overflow-tooltip="true" width="120px"></el-table-column>
				<el-table-column v-if="$tools.isShow('picname', tableShowList)" prop="picname" label="缩略图" :show-overflow-tooltip="true" width="100px">
					<template slot-scope="scope">
						<el-image v-if="scope.row.picname" :src="scope.row.picname" style="width: 60px; height: 60px" :preview-src-list="[scope.row.picname]" />
					</template>
				</el-table-column>
				<el-table-column v-if="$tools.isShow('click', tableShowList)" prop="click" label="浏览次数" :show-overflow-tooltip="true" width="80px"></el-table-column>
				<el-table-column v-if="$tools.isShow('pubdate', tableShowList)" prop="pubdate" label="发布时间" :show-overflow-tooltip="true" width="230px"></el-table-column>
				<el-table-column v-if="$tools.isShow('status', tableShowList)" prop="status" label="状态" :show-overflow-tooltip="true" :formatter="statusFmt" width="80px"></el-table-column>

				<!-- <el-table-column
					v-if="$tools.isShow('author', tableShowList)"
					prop="author"
					label="作者"
					:show-overflow-tooltip="true"
				></el-table-column>
				<el-table-column
					v-if="$tools.isShow('source', tableShowList)"
					prop="source"
					label="来源"
					:show-overflow-tooltip="true"
				></el-table-column>
				<el-table-column
					v-if="$tools.isShow('info', tableShowList)"
					prop="info"
					label="摘要"
					:show-overflow-tooltip="true"
				></el-table-column>
				<el-table-column
					v-if="$tools.isShow('keywords', tableShowList)"
					prop="keywords"
					label="关键字"
					:show-overflow-tooltip="true"
				></el-table-column>
				
				<el-table-column
					v-if="$tools.isShow('publisher', tableShowList)"
					prop="publisher"
					label="发布人"
					:show-overflow-tooltip="true"
				></el-table-column>
				
				<el-table-column
					v-if="$tools.isShow('url', tableShowList)"
					prop="url"
					label="访问地址"
					:show-overflow-tooltip="true"
				></el-table-column>
				 -->
				<el-table-column v-if="$tools.isShow('sort', tableShowList)" prop="sort" label="权重排序" :show-overflow-tooltip="true" width="100px"></el-table-column>

				<el-table-column label="操作" fixed="right" width="180">
					<template slot-scope="scope">
						<div>
							<!-- 查看 -->
							<el-button
								v-if="$tools.hasPermission('cms:cmsArticle:info') && scope.row.status == 2"
								size="mini"
								@click="view(scope.row.url)"
								icon="el-icon-view"
								type="primary"
								title="页面预览"
							></el-button>
							<!-- 编辑 -->
							<el-button v-if="$tools.hasPermission('cms:cmsArticle:edit')" size="mini" @click="handleEdit(scope.row)" icon="el-icon-edit" type="warning" title="编辑"></el-button>
							<!-- 删除 -->
							<el-button
								v-if="$tools.hasPermission('cms:cmsArticle:toGarbage') && queryForm.status != 7"
								size="mini"
								type="danger"
								@click="handleDeleteBatch([scope.row])"
								icon="el-icon-delete"
								title="放入回收站"
							></el-button>
							<el-button
								v-if="$tools.hasPermission('cms:cmsArticle:delete') && queryForm.status == 7"
								size="mini"
								type="danger"
								@click="onCompletelyDelete([scope.row.id])"
								icon="el-icon-delete"
								title="彻底删除"
							></el-button>
						</div>
					</template>
				</el-table-column>
			</el-table>
		</loading>
		<pagination :total="page.total" :current-page="page.current" :page-size="page.size" @refreshData="queryList"></pagination>
		<!-- 新增、编辑 -->
		<form-edit v-if="formEditVisible" ref="formEdit" :leftTreeData="leftTreesimple" @refreshData="queryList"></form-edit>
		<!-- 详情 -->
		<form-info v-if="formInfoVisible" ref="formInfo"></form-info>

		<el-dialog :visible.sync="category.visible" title="转移分类">
			<el-tree class="filter-tree" :data="leftTreeData" :props="category.prop" ref="tree" default-expand-all highlight-current @node-click="onCheckedNodeClick">
				<template #default="{data}">{{ data.name }} ( {{ formatCategroy(data) }} )</template>
			</el-tree>
			<template #footer>
				<el-button @click="category.visible = false">取 消</el-button>
				<el-button type="primary" @click="onCategorySubmit()">确 定</el-button>
			</template>
		</el-dialog>
	</div>
</template>
<script>
import { cmsarticlePage, cmsarticleDel, cmsarticleDelBatch, cmsarticleDynamicExport, leftTreeList } from "@/api/cms/cmsarticle.js"
import { viewTableList } from "@/api/public.api.js"
import FormEdit from "./cmsarticle-edit"
import FormInfo from "./cmsarticle-info"
import FortressPagination from "@/components/fortress-pagination.vue"
import { enumList } from "@/api/public.api.js"
import request from "@/common/request"

export default {
	data() {
		return {
			leftTreeHeight: 0,
			leftTreeFilterText: "",
			parentShow: false,
			tableData: [],
			leftTreeData: [],
			leftTreesimple: [],
			defaultProps: {
				children: "children",
				label: function treeNameHandle(data) {
					let c = data.category == 1 ? "栏目" : data.category == 2 ? "封面" : data.category == 3 ? "外链" : ""
					return data.name + (c ? "|(" + c + ")" : "")
				},
			},
			sleLeftTreeNode: {},
			sleLeftTreeId: "",
			sleLeftTreeName: "",
			formEditVisible: false,
			formInfoVisible: false,
			queryForm: {
				id: "",
				title: "",
				author: "",
				keywords: "",
				publisher: "",
				status: "",
			},
			page: {
				current: 1,
				size: 10,
				total: 0,
			},
			collapse: {
				icon: "el-icon-arrow-down el-icon--right",
				label: "展开",
				flag: false,
			},
			tableList: [],
			tableShowList: [],
			ArticleStatus_cmsList: [],
			pickerOptions: {
				shortcuts: [
					{
						text: "最近一周",
						onClick(picker) {
							const end = new Date()
							const start = new Date()
							start.setTime(start.getTime() - 3600 * 1000 * 24 * 7)
							picker.$emit("pick", [start, end])
						},
					},
					{
						text: "最近一个月",
						onClick(picker) {
							const end = new Date()
							const start = new Date()
							start.setTime(start.getTime() - 3600 * 1000 * 24 * 30)
							picker.$emit("pick", [start, end])
						},
					},
					{
						text: "最近三个月",
						onClick(picker) {
							const end = new Date()
							const start = new Date()
							start.setTime(start.getTime() - 3600 * 1000 * 24 * 90)
							picker.$emit("pick", [start, end])
						},
					},
				],
			},
			multipleSelection: [],

			category: {
				visible: false,
				checked: {},
				prop: {
					label: "name",
					value: "id",
				},
			},

			tagsList: [],
			date: [],
			queryFormtags: [],
		}
	},
	computed: {
		crossState() {
			if (!this.multipleSelection.length) return false
			const status = this.multipleSelection[0].status
			return !this.multipleSelection.some(item => item.status != status)
		},
	},

	async created() {
		this.leftTreeHeight = window.innerHeight * 0.8
		this.queryEnumList()
		this.queryLeftTreeList()
		this.initTableList()
		this.queryList()

		try {
			const { code, data, msg } = await request("get", "/cms/cmsCustTag/list")
			if (code != 0) {
				throw new Error(msg)
			}
			this.tagsList = data.map(item => ({
				code: item.id,
				name: item.title,
			}))
		} catch (error) {
			this.$message.error(error)
		}
	},
	watch: {
		// leftTreeFilterText(val) {
		// 	this.$refs.tree.filter(val)
		// },
		queryFormtags() {
			this.queryForm.queryTags = this.queryFormtags.join(",")
		},
	},
	methods: {
		view(url) {
			let winurl = window.$conf.commonConf.baseUrl.replace(/\/$/, "") + "/"

			window.open(winurl + url.replace(/^\//, ""), "_view")
		},
		onQueryListDate(date) {
			this.queryForm.pubdateStart = date[0]
			this.queryForm.pubdateEnd = date[1]
		},
		formatCategroy(item) {
			return ["", "列表栏目", "封面栏目", "外链栏目"][item.category]
		},
		onCheckedNodeClick(data) {
			this.category.checked = data
		},
		onCategorySubmit(ids) {
			if (!this.category.checked.id) return this.$message.error("请选择栏目")
			if (this.category.checked.category != 1) return this.$message.error("请选择列表栏目")

			ids = ids || this.multipleSelection.map(item => item.id)
			this.$confirm("此操作将转移分类, 是否继续?", "提示", {
				confirmButtonText: "确定",
				cancelButtonText: "取消",
				type: "warning",
			}).then(async () => {
				try {
					const { code, msg } = await request("post", "/cms/cmsArticle/moveChannel", {
						ids,
						channelId: this.category.checked.id,
					})
					if (code != 0) {
						throw new Error(msg)
					}
					this.initTableList()
					this.queryList()
					this.$message({
						type: "success",
						message: "操作成功",
					})
					this.category.checked = {}
					this.category.visible = false
				} catch (error) {
					this.$message.error(error)
				}
			})
		},
		onCategoryVisible() {
			this.category.visible = true
		},
		handleSelectionChange(val) {
			this.multipleSelection = val
		},
		onCompletelyDelete(ids) {
			ids = ids || this.multipleSelection.map(item => item.id)
			this.$confirm("确认删除该记录，数据将无法恢复, 是否继续?", "提示", {
				confirmButtonText: "确定",
				cancelButtonText: "取消",
				type: "warning",
			}).then(async () => {
				try {
					const { code, msg } = await request("post", "/cms/cmsArticle/toDelReal", ids)
					if (code != 0) {
						throw new Error(msg)
					}
					this.initTableList()
					this.queryList()
					this.$message({
						type: "success",
						message: "删除成功",
					})
				} catch (error) {
					this.$message.error(error)
				}
			})
		},
		toDrafts(ids) {
			ids = ids || this.multipleSelection.map(item => item.id)
			this.$confirm("该操作将把文章放入草稿箱, 是否继续?", "提示", {
				confirmButtonText: "确定",
				cancelButtonText: "取消",
				type: "warning",
			}).then(async () => {
				try {
					const { code, msg } = await request("post", "/cms/cmsArticle/toDrafts", ids)
					if (code != 0) {
						throw new Error(msg)
					}
					this.initTableList()
					this.queryList()
					this.$message({
						type: "success",
						message: "操作成功",
					})
				} catch (error) {
					this.$message.error(error)
				}
			})
		},
		tabClick(event) {
			this.queryForm.status = +event.paneName ? +event.paneName - 1 + "" : ""
			this.queryList({ current: 1 })
		},
		queryEnumList() {
			this.ArticleStatus_cmsList = []
			enumList("ArticleStatus", "cms").then(resp => {
				if (resp.code == 0) {
					this.ArticleStatus_cmsList = resp.data
				}
			})
		},
		//查询左树数据
		queryLeftTreeList() {
			this.leftTreeData = []
			leftTreeList().then(resp => {
				if (resp.code == 0) {
					this.leftTreesimple = resp.data
					this.leftTreeData = this.leftTreeData.concat(this.leftTreesimple)
				} else {
					this.$msg({
						message: resp.msg,
						type: "error",
					})
				}
			})
		},
		leftTreeFilterNode(value, data) {
			if (!value) return true
			return data.name.indexOf(value) !== -1
		},
		//点选左侧树
		chooseLeftTree(data) {
			if (data.id == -1) {
				this.sleLeftTreeNode = {}
				this.sleLeftTreeId = ""
				this.sleLeftTreeName = ""
				this.queryRightTable("")
			} else {
				this.sleLeftTreeNode = data
				this.sleLeftTreeId = data.id
				this.sleLeftTreeName = data.name
				this.queryRightTable(data.id)
			}
		},
		selectClear() {
			this.sleLeftTreeNode = {}
			this.sleLeftTreeId = ""
			this.sleLeftTreeName = ""
			this.queryRightTable("")
		},
		//点击左树筛选右侧表格数据
		queryRightTable(sleLeftTreeId) {
			this.queryForm.channelId = sleLeftTreeId
			this.queryList()
		},
		refresh() {
			this.tableData = []
			this.queryList({ current: 1 })
		},
		//查询表格数据
		queryList(page) {
			this.parentShow = true
			if (page) {
				this.page.current = page.current ? page.current : this.page.current
				this.page.size = page.size ? page.size : this.page.size
			}
			this.queryForm.current = this.page.current
			this.queryForm.size = this.page.size
			cmsarticlePage(this.queryForm).then(resp => {
				if (resp.code == 0) {
					this.tableData = resp.data.records
					this.page.total = resp.data.total
					//查询页大于总页数，重新查询
					let cu = this.page.total % this.page.size == 0 ? parseInt(this.page.total / this.page.size) : parseInt(this.page.total / this.page.size + 1)
					if (cu > 0 && this.page.current > cu) {
						this.queryList({ current: cu })
					}
				} else {
					this.$msg({
						message: resp.msg,
						type: "error",
					})
				}
				this.parentShow = false
			})
		},
		//打开编辑窗口
		handleEdit(row) {
			if (row) {
				this.$router.push("/cms/cmsarticle-edit?id=" + row.id)
			} else {
				this.$router.push("/cms/cmsarticle-edit")
			}
			//新增
			// if (!row) {
			// 	if (!this.sleLeftTreeId || this.sleLeftTreeNode.category != 1) {
			// 		this.$msg({
			// 			message: "请选择列表类型栏目",
			// 			type: "error",
			// 		})
			// 		return
			// 	}
			// }
			// this.formEditVisible = true
			// this.$nextTick(() => {
			// 	if (row) {
			// 		this.$refs.formEdit.init(row.id, row.channelId)
			// 	} else {
			// 		this.$refs.formEdit.init(undefined, this.sleLeftTreeId, this.sleLeftTreeName)
			// 	}
			// })
		},
		//打开详情窗口
		handleInfo(id) {
			this.formInfoVisible = true
			this.$nextTick(() => {
				this.$refs.formInfo.init(id)
			})
		},
		//删除
		handleDelete(row) {
			this.$confirm("确认删除该记录, 是否继续?", "提示", {
				confirmButtonText: "确定",
				cancelButtonText: "取消",
				type: "warning",
			})
				.then(() => {
					cmsarticleDel(row.id).then(resp => {
						if (resp.code == 0) {
							this.$message({
								type: "success",
								message: "操作成功!",
							})
							//判断是否最后一页的最后一条记录
							let totalPages = (this.page.total - 1) % this.page.size == 0 ? (this.page.total - 1) / this.page.size : (this.page.total - 1) / this.page.size + 1
							if (this.page.current > totalPages && this.page.current != 1) {
								this.page.current = this.page.current - 1
							}
							this.queryList()
						} else {
							this.$msg({
								message: resp.msg,
								type: "error",
							})
						}
					})
				})
				.catch(() => {})
		},
		//批量删除
		handleDeleteBatch(ids) {
			let checkedRow = ids || this.$refs.multipleTable.selection
			if (checkedRow.length > 0) {
				let ids = []
				checkedRow.forEach(item => {
					ids.push(item.id)
				})
				this.$confirm("是否放入回收站, 是否继续?", "提示", {
					confirmButtonText: "确定",
					cancelButtonText: "取消",
					type: "warning",
				})
					.then(async () => {
						try {
							const { code, msg } = await request("post", "/cms/cmsArticle/toGarbage", ids)

							if (code != 0) {
								throw new Error(msg)
							}
							this.$message({
								type: "success",
								message: "操作成功!",
							})
							//判断是否最后一页的最后一条记录
							let totalPages =
								(this.page.total - checkedRow.length) % this.page.size == 0
									? (this.page.total - checkedRow.length) / this.page.size
									: (this.page.total - checkedRow.length) / this.page.size + 1
							if (this.page.current > totalPages && this.page.current != 1) {
								this.page.current = this.page.current - 1
							}
							this.queryList()
						} catch (error) {
							this.$msg({
								message: error,
								type: "error",
							})
						}
					})
					.catch(() => {})
			} else {
				this.$msg({
					message: "请选择数据进行删除",
					type: "error",
				})
			}
		},
		//重置查询框
		resetQueryForm() {
			this.queryForm = {
				id: "",
				title: "",
				author: "",
				keywords: "",
				publisher: "",
				status: "",
				channelId: this.sleLeftTreeId,
			}
		},
		//切换查询条件收缩框
		handleCollapseState() {
			this.collapse.flag = !this.collapse.flag
			if (this.collapse.flag) {
				this.collapse.icon = "el-icon-arrow-up el-icon--right"
				this.collapse.label = "收起"
			} else {
				this.collapse.icon = "el-icon-arrow-down el-icon--right"
				this.collapse.label = "展开"
			}
		},
		//视图表格列表初始化
		initTableList() {
			viewTableList("cms_article").then(resp => {
				if (resp.code == 0) {
					this.tableList = resp.data
					this.tableList.forEach(item => {
						this.tableShowList.push(item.propName)
					})
				}
			})
		},
		//状态格式化返回
		statusFmt(row) {
			let name = ""
			if (this.ArticleStatus_cmsList) {
				this.ArticleStatus_cmsList.forEach(item => {
					if (item.code == row.status) {
						name = item.name
					}
				})
			}
			return name
		},
		//可见字段excel导出
		handleExport() {
			if (!this.tableShowList || this.tableShowList.length < 1) {
				this.$msg({
					message: "请选择要导出的列",
					type: "error",
				})
				return
			}
			let colNum = 1
			let headerList = []
			this.tableShowList.forEach(item => {
				let nameData = this.tableList.find(item2 => {
					return item2.propName == item
				})
				let name = ""
				if (nameData && nameData.propDesc) {
					name = nameData.propDesc
				} else {
					name = "未定义字段" + colNum++
				}
				headerList.push({ name: name, code: item })
			})
			cmsarticleDynamicExport({ headerList: headerList, dto: this.queryForm })
		},
	},
	components: {
		"form-edit": FormEdit,
		"form-info": FormInfo,
		pagination: FortressPagination,
	},
}
</script>
<style lang="scss">
.cmsarticle-el-tabs {
	.el-tabs__nav-wrap {
		&::after {
			height: 1px;
		}
	}
}
</style>
<style lang="scss" scoped>
.padding10 {
	padding: 10px 20px;
	background-color: #fff;
	/* max-height: 600px; */
	overflow: auto;
	border-radius: 4px;
	box-shadow: 0 1px 2px 0 rgba(#000, 0.05);
}
.tree {
	height: 600px;
	overflow: auto;
}
.ditct {
	display: flex;
	justify-content: flex-end;
	align-items: center;
}
</style>
